package com.sg.controller.bff;

import com.sg.service.biz.bff.ChangeColumnService;
import com.sg.dto.biz.bff.req.*;
import com.sg.dto.biz.bff.res.*;
import com.sg.common.ro.OkrResult;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author ：
 * @version 1.0
 * @date ：
 */
@Api(value = "ChangeColumn", tags = {"ChangeColumn"})
@RestController
// @RequestMapping("/oms/changeColumn/")
public class ChangeColumnController {

    @Autowired
    ChangeColumnService changeColumnService;

    /**
     * （1111待确认后删除）B1-修订批次外内容（公共）
     * gen by moon at 8/10/2022, 3:36:50 AM
     */
    @PostMapping("/oms/mgt/changeColumn/reviseNotBatchContentCom")
    @ApiOperation(value = "（1111待确认后删除）B1-修订批次外内容（公共）", response = OkrResult.class)
    public OkrResult<BffReviseNotBatchContentComRespDto> reviseNotBatchContentCom(@RequestBody(required = false) @Validated BffReviseNotBatchContentComReqDto reqDTO) {
        return OkrResult.success(changeColumnService.reviseNotBatchContentCom(reqDTO));
    }

    /**
     * B1-1撤销修订底层变更字段（公共）
     * gen by moon at 7/23/2022, 9:48:12 PM
     */
    @PostMapping("/oms/mgt/changeColumn/undoReviseBaseChangeCol")
    @ApiOperation(value = "B1-1撤销修订底层变更字段（公共）", response = OkrResult.class)
    public OkrResult<BffUndoReviseBaseChangeColRespDto> undoReviseBaseChangeCol(@RequestBody(required = false) @Validated BffUndoReviseBaseChangeColReqDto reqDTO) {
        return OkrResult.success(changeColumnService.undoReviseBaseChangeCol(reqDTO));
    }

    /**
     * B1-修订批次下内容（公共）
     * gen by moon at 7/23/2022, 9:47:42 PM
     */
    @PostMapping("/oms/mgt/changeColumn/reviseBatchContentCom")
    @ApiOperation(value = "B1-修订批次下内容（公共）", response = OkrResult.class)
    public OkrResult<BffReviseBatchContentComRespDto> reviseBatchContentCom(@RequestBody(required = false) @Validated BffReviseBatchContentComReqDto reqDTO) {
        return OkrResult.success(changeColumnService.reviseBatchContentCom(reqDTO));
    }

    /**
     * B1-查底层变更字段列表
     */
    @PostMapping("/oms/mgt/changeColumn/queryBaseChangeColList")
    @ApiOperation(value = "B1-查底层变更字段列表", response = OkrResult.class)
    public OkrResult<BffQueryBaseChangeColListRespDto> queryBaseChangeColList(@RequestBody(required = false) @Validated BffQueryBaseChangeColListReqDto reqDTO) {
        return OkrResult.success(changeColumnService.queryBaseChangeColList(reqDTO));
    }

    /**
     * B1-1查询组织变更记录列表(管理)
     * gen by moon at 8/10/2022, 3:38:48 AM
     */
    @PostMapping("/oms/mgt/changeColumn/queryOrgChangeRecordList")
    @ApiOperation(value = "B1-1查询组织变更记录列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryOrgChangeRecordListRespDto> queryOrgChangeRecordList(@RequestBody(required = false) @Validated BffQueryOrgChangeRecordListReqDto reqDTO) {
        return OkrResult.success(changeColumnService.queryOrgChangeRecordList(reqDTO));
    }

    /**
     * B1-3修订组织批次下内容(管理)
     * gen by moon at 9/5/2022, 2:09:09 AM
     */
    @PostMapping("/oms/mgt/changeColumn/reviseOrgAtchContent")
    @ApiOperation(value = "B1-3修订组织批次下内容(管理)", response = OkrResult.class)
    public OkrResult<BffReviseOrgAtchContentRespDto> reviseOrgAtchContent(@RequestBody(required = false) @Validated BffReviseOrgAtchContentReqDto reqDTO) {
        return OkrResult.success(changeColumnService.reviseOrgAtchContent(reqDTO));
    }

    /**
     * B1-3撤销修订部门资料(管理)
     * gen by moon at 8/10/2022, 3:31:14 AM
     */
    @PostMapping("/oms/mgt/changeColumn/undoReviseDeptInfo")
    @ApiOperation(value = "B1-3撤销修订部门资料(管理)", response = OkrResult.class)
    public OkrResult<BffUndoReviseDeptInfoRespDto> undoReviseDeptInfo(@RequestBody(required = false) @Validated BffUndoReviseDeptInfoReqDto reqDTO) {
        return OkrResult.success(changeColumnService.undoReviseDeptInfo(reqDTO));
    }

    /**
     * B1-3修订部门资料(管理)
     * gen by moon at 9/4/2022, 3:32:20 AM
     */
    @PostMapping("/oms/mgt/changeColumn/reviseDeptInfo")
    @ApiOperation(value = "B1-3修订部门资料(管理)", response = OkrResult.class)
    public OkrResult<BffReviseDeptInfoRespDto> reviseDeptInfo(@RequestBody(required = false) @Validated BffReviseDeptInfoReqDto reqDTO) {
        return OkrResult.success(changeColumnService.reviseDeptInfo(reqDTO));
    }

    /**
     * B1-3撤销修订组织批次下内容(管理)
     * gen by moon at 8/10/2022, 3:38:50 AM
     */
    @PostMapping("/oms/mgt/changeColumn/undoReviseOrgAtchContent")
    @ApiOperation(value = "B1-3撤销修订组织批次下内容(管理)", response = OkrResult.class)
    public OkrResult<BffUndoReviseOrgAtchContentRespDto> undoReviseOrgAtchContent(@RequestBody(required = false) @Validated BffUndoReviseOrgAtchContentReqDto reqDTO) {
        return OkrResult.success(changeColumnService.undoReviseOrgAtchContent(reqDTO));
    }

    /**
     * B1-1查询部门变更记录列表(管理)
     * gen by moon at 8/18/2022, 10:22:01 PM
     */
    @PostMapping("/oms/mgt/changeColumn/queryDeptChangeRecordList")
    @ApiOperation(value = "B1-1查询部门变更记录列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryDeptChangeRecordListRespDto> queryDeptChangeRecordList(@RequestBody(required = false) @Validated BffQueryDeptChangeRecordListReqDto reqDTO) {
        return OkrResult.success(changeColumnService.queryDeptChangeRecordList(reqDTO));
    }

    /**
     * B1-判断重置修订元素(管理)
     * gen by moon at 9/2/2022, 5:09:31 PM
     */
    @PostMapping("/oms/mgt/changeColumn/judgeReviseElement")
    @ApiOperation(value = "B1-判断重置修订元素(管理)", response = OkrResult.class)
    public OkrResult<BffJudgeReviseElementRespDto> judgeReviseElement(@RequestBody(required = false) @Validated BffJudgeReviseElementReqDto reqDTO) {
        return OkrResult.success(changeColumnService.judgeReviseElement(reqDTO));
    }

    /**
     * B3-13查询评价模板变更记录列表(管理)
     * gen by moon at 10/23/2022, 2:36:45 PM
     */
    @PostMapping("/oms/mgt/changeColumn/queryEvaChangeRecordList")
    @ApiOperation(value = "B3-13查询评价模板变更记录列表(管理)", response = OkrResult.class)
    public OkrResult<BffQueryEvaChangeRecordListRespDto> queryEvaChangeRecordList(@RequestBody(required = false) @Validated BffQueryEvaChangeRecordListReqDto reqDTO) {
        return OkrResult.success(changeColumnService.queryEvaChangeRecordList(reqDTO));
    }

    /**
     * B3-判断业务应用重置修订元素(管理)
     * gen by moon at 10/8/2022, 3:11:21 AM
     */
    @PostMapping("/oms/mgt/changeColumn/judgeAppReviseElement")
    @ApiOperation(value = "B3-判断业务应用重置修订元素(管理)", response = OkrResult.class)
    public OkrResult<BffJudgeAppReviseElementRespDto> judgeAppReviseElement(@RequestBody(required = false) @Validated BffJudgeAppReviseElementReqDto reqDTO) {
        return OkrResult.success(changeColumnService.judgeAppReviseElement(reqDTO));
    }

    /**
     * B3撤销修订评价批次下指标(管理)
     * gen by moon at 11/4/2022, 7:38:13 AM
     */
    @PostMapping("/oms/mgt/changeColumn/undoReviseEvaBatchTarget")
    @ApiOperation(value = "B3撤销修订评价批次下指标(管理)", response = OkrResult.class)
    public OkrResult<BffUndoReviseEvaBatchTargetRespDto> undoReviseEvaBatchTarget(@RequestBody(required = false) @Validated BffUndoReviseEvaBatchTargetReqDto reqDTO) {
        return OkrResult.success(changeColumnService.undoReviseEvaBatchTarget(reqDTO));
    }

    /**
     * B3-13查询评价模板变更记录列表(管理)(边界)
     * gen by moon at 6/10/2023, 1:13:25 AM
     */
    @PostMapping("/oms/mgt/changeColumn/queryEvaChangeRecordListBorder")
    @ApiOperation(value = "B3-13查询评价模板变更记录列表(管理)(边界)", response = OkrResult.class)
    public OkrResult<BffQueryEvaChangeRecordListBorderRespDto> queryEvaChangeRecordListBorder(@RequestBody(required = false) @Validated BffQueryEvaChangeRecordListBorderReqDto reqDTO) {
        return OkrResult.success(changeColumnService.queryEvaChangeRecordListBorder(reqDTO));
    }
}
